<!doctype html>
<html>

	<head>
		<meta charset="utf-8">
		<title></title>
		<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
		<link href="../common/mui/mui.css" rel="stylesheet" />
		<link href="../common/css/app.css" rel="stylesheet" />
		<style type="text/css">
			.mui-title{
				font-size: 16px;
			}
			.mui-bar a, header>.mui-icon-left-nav:before{
				color: var(--mainColor);
			}
		</style>
	</head>

	<body>
		<header class="mui-bar mui-bar-nav">
			<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
			<h1 class="mui-title" id="title"></h1>
		</header>
		<script src="../common/mui/mui.js"></script>
		<script type="text/javascript">
			mui.init()
			mui.plusReady(function() {
				var self=plus.webview.currentWebview()
				mui('#title')[0].innerText = self.title
				var sourceData = self.sourceData||''
				if (self.pageType != '' && self.pageType != undefined) {
					localStorage['trainSubID']=sourceData['subID']
				}
				var detailPage = plus.webview.create(
					"web/viewer.html?file="+self.fileUrl,
					"viewer", {
						width: '100%',
						left: '0px',
						right: '0px',
						top: '44px',
						bottom: '0px',
						zindex: 10,
						margin: 'auto',
						opacity: 1,
						mask: 'none',
						bounce: 'none',
						scalable: true
					},{sourceData:sourceData,pageType:(self.pageType||'')});
				self.append(detailPage)
				detailPage.id = 'viewer'
				mui.back = function(){
					detailPage.close()
					plus.webview.currentWebview().close();
				}
			});
		</script>
	</body>

</html>
